from AIAssistant import AIAssistant
class ImageGenerationAssistant(AIAssistant):
    """子类：图片生成助手"""

    def __init__(self, aid: str, name: str, version: str, is_online: bool, ability_score: int, max_resolution: str):
        super().__init__(aid, name, "图片生成", version, is_online, ability_score)
        self.max_resolution = max_resolution

    def execute_task(self, task_content: str) -> str:
        return f"[{self.get_name()}] 执行图片生成任务：\n任务内容：{task_content}\n生成结果：已生成符合描述的图片，分辨率：{self.max_resolution}"

    def get_max_resolution(self) -> str:
        return self.max_resolution

    def set_max_resolution(self, max_resolution: str) -> None:
        self.max_resolution = max_resolution

    def __str__(self) -> str:
        return super().__str__() + f", 最大分辨率: {self.max_resolution}"  # 修复6: 添加分隔符